home *** CD-ROM | disk | FTP | other *** search
/ Belgian Amiga Club - ADF Collection / BS1 part 41.zip / BS1 part 41 / Crunchers pack v1.5.adf / DOCS / TETRAPACKER-V2.2.DOC < prev    next >
Text File  |  1987-03-07  |  13KB  |  377 lines

  1. --------------------------------------------------------------
  2.                     TETRAPACK Version 2.1
  3. --------------------------------------------------------------
  4.  
  5.    TetraPack Version 2.1 is a  new  version  of  TetraCrunch with
  6. rewritten memory management routines, a new decruncher and a mega
  7. crunch option which  allows  crunching  of  programs up to $7ff00
  8. bytes long (511.75 Kb!!). The  cruncher  is (and has always been)
  9. the very best on the 'market' at this moment.
  10.  
  11.                             CREDITS:
  12.  
  13.     User Interface, Decrunchers, Research, and Crunchers by:
  14.  
  15.                            ANTIACTION.
  16.  
  17.         With thanks to LORD BLITTER, IL SCURO, and LASER.
  18.  
  19.  
  20. INSTRUCTIONS
  21. ------------
  22.  
  23.   There are actually two  crunchers  in  TetraPack, one 'Amateur'
  24. version, which handles normal  programs  in  much the same way as
  25. Byte  Killer,  Flash-Packer  (RSI),  and  TetraCrunch.  And  then
  26. there's a  'Professional'  version,  which  handles programs from
  27. $0000-$7ffff. The  professional  version  should  only be used to
  28. pack games or demos which  doesn't  use the Operating System. For
  29. example: KATAKIS, TLC POWERTRAX, PANDORA, NETHERWORLD, NEBULUS et
  30. cetera. The name 'professional'  implies  that  this version only
  31. should be used by experienced programmers and crackers.
  32.  
  33.   The following instructions  applies  both to Mega-Crunch (Pro),
  34. and The normal crunch.
  35.  
  36. NOTE: Whenever T.P.  asks  for  anything  else  than  RETURN or a
  37. hexadecimal number, you can  type  an  asterisk (*) followed by a
  38. command or program name to execute  a command/Program, useful for
  39. loading a monitor and alter something before crunching!!
  40.  
  41.   First TetraPack asks:
  42.  
  43. Mega-Crunch (Y/N) ? 
  44.  
  45. Here you simply type Y if you want  megacrunch, and N if you want
  46. normal crunch. Next, the program asks:
  47.  
  48. Low-Mem: $
  49.  
  50. Here you are supposed to  enter  the  lowest  address  which your
  51. program uses. Next, TP asks:
  52.  
  53. High-Mem: $
  54.  
  55. Here you should enter  the  highest  address  which your programs
  56. uses. Actually  you  should  always  specify  a  high-mem that is
  57. higher that the actual  program's  last  address. (Because of the
  58. way the first pass cruncher works). Also,  another thing to  take
  59. into account when selecting high-mem's  is the fact that when the
  60. program later on is loaded  from disk, it will possibly be loaded
  61. into a position so  that it overlaps  the decrunch-area, to avoid
  62. this, ALWAYS CHOOSE A  HIGH-MEM OF AT  LEAST $50000. THIS IS VERY
  63. IMPORTANT!!! (USING A HIGH HIGH-MEM DOES NOT AFFECT THE PROGRAM
  64. SIZE BY MORE THAN APPROX. 5 BYTES PER EVERY 64 KBYTES!! SO USE AS
  65. HIGH HIGH-MEM's AS POSSIBLE!)
  66.  
  67.  
  68.   Next TP clears the allocated memory to obtain optimal crunching
  69. performance. Now TetraPack asks:
  70.  
  71. Scan-Width ($10-$8000): $
  72.  
  73. This number specifies how many  bytes  forward the equal-sequence
  74. packer should look for an equal  sequence,  the  general rule is:
  75. the higher a scan-width, the  smaller  program,  but it will also
  76. take longer time to crunch. However,  this is not always true, as
  77. you soon shall see the optimal scan-width  is almost always $800.
  78. When selecting a  Scan-Width,  do  not  just take one out of thin
  79. air, like $35d or $57, these  are  not very efficient. No, always
  80. use an even power of two, like $40,  $80, $100, $200, $400, $800,
  81. $1000, $2000, $4000, $8000. NOTHING INBETWEEN!!! Another rule is,
  82. if you double the scan-width, you also double the crunching time.
  83.  
  84.   The next stage is to enter all  files  to  load into memory, so
  85. the next question is:
  86.  
  87. Load type (r=Reloc, o=Plain, t=TrackDisk):
  88.  
  89.   As you can see, there are several  different types of loads, an
  90. explanation:
  91.  
  92. R - RELOC:
  93.  
  94. This option loads a CLI executable  file into a fixed location in
  95. memory, i.e. a file saved from  seka  with the command WO, or the
  96. Object file from DEVPAC.  One  should  note,  that you should not
  97. crunch CLI commands as DIR etc. with this cruncher, for that, use
  98. the TNM-Cruncher, ANC Cruncher, Relokit, or any similar cruncher.
  99. So what can this load-option  do??  Well,  it is VERY useful when
  100. putting demo's  together,  as  you  can  save  the Object code as
  101. Relocateable (CLI) code, and then,  when you are going to crunch,
  102. you can load the code into any  memory  location you want. Useful
  103. for MegaDemos (I can tell...)!!. Also,  you can crunch some games
  104. using this option, like Thundercats,  for example, which is saved
  105. as one reloc-file.
  106.  
  107. O - PLAIN:
  108.  
  109. This option  simply  loads  a  file  into  memory,  and  makes no
  110. alterations to it's contents,  I.E.  you  can load a text file, a
  111. picture, a sample or anything else  into memory. Works like RI in
  112. SEKA.
  113.  
  114. T - TRACKDISK:
  115.  
  116. This option loads data straight from AmigaDOS sectors.It asks for
  117. OFFSET, and for LENGTH, these should be entered as even multiples
  118. of $200. The values are exactly  like  those put into the ExtTDIo
  119. structure when doing bootblock loaders etc. Useful when crunching
  120. games!!!
  121.  
  122.  
  123. You can go on loading  files/sectors as many times you want. When
  124. you are finished with the loading of data, just press return, and
  125. TetraPack will start it's REAL work...
  126.  
  127. When it is finished with the  crunching,  it will display how big
  128. the crunched file is, and how many bytes was won, press RETURN to
  129. continue.
  130.  
  131. Now TP asks you to enter the JMP/JSR address, which simply is the
  132. starting address of your code (start of program).
  133.  
  134. When you have entered the JMP address, you will be asked:
  135.  
  136. Next TetraPack asks something like:
  137. Flash-register: etc....
  138.  
  139. Here you choose in which color register the depacker should place
  140. the flash values, $00 is background, $01 foreground 1 etc. To get
  141. rid of the  flashing, simply  select $10. (Not  used on workbench
  142. screen). Next TetraPack asks:
  143.  
  144. PRO-DECRUNCHER? (Y/N):
  145.  
  146. If you want the 'pro' version of the decruncher, then answer yes,
  147. if you don't, just press return, or answer no.  If you select the
  148. pro-decruncher, you will have the same decrunch-possibilities as
  149. in the MEGA version of the cruncher.
  150.  
  151. If you are working  in  MEGACRUNCH  mode,  or if you answered yes
  152. on the question above, you  will now get  some further questions,
  153. these are described later.
  154.  
  155. At this point TetraPack asks for a name, which is the name of the
  156. crunched file. If you don't want to  save the crunched file, just
  157. press RETURN, or enter NIL:, to avoid saving.
  158.  
  159. Next TetraPack asks if you would want  to save again, answer Y or
  160. N. If you answer No, TetraPack will ask you:
  161.  
  162. Want to run? (Y/N): 
  163.  
  164. If you answer Y here, TetraPack will run the packed program with-
  165. out reloading it. If you answer NO, TetraPack will end.
  166.  
  167.                              MEGACRUNCH
  168.                            --------------
  169.  
  170. NOTE:  Before using this option,  you have to remove the fastmem
  171. from the SYSTEM. Note: NOT  physically,  use the TETRAGON NoFast
  172. program, or the C.C.S. NOFAST BOOT. No other programs will work,
  173. because they don't remove EXEC.LIBRARY etc from fastmem.
  174.  
  175. This option needs  1  MegaByte  of  memory,  otherwise  it  works
  176. exactly  as  'mini'   crunch,   but  for  these  questions  after
  177. JMP-address:
  178.  
  179. DMA :
  180.  
  181. Simply the value to load $dff096 (DMACON)  with before jumping to
  182. the start of the code.
  183.  
  184. ADK :
  185.  
  186. As DMA, but the address is $dff09e (ADKCON).
  187.  
  188. INT :
  189.  
  190. As DMA & ADK, but the address is $dff09a (INTENA)
  191.  
  192. STACK :
  193.  
  194. Enter the desired  stack  pointer.  In  other words, the value to
  195. load register A7 with.
  196.  
  197. STATUS REG.:
  198.  
  199. Enter the desired value to load  SR  with before jumping to start
  200. of code.
  201.  
  202. DECRUNCHER LOCATION:
  203.  
  204. Enter the address where  the  decruncher  is  to be located, this
  205. should be at least $40  lower  than  low-mem,  or equal or higher
  206. than the hi-mem. The deccruncher should  though not be located at
  207. a higher location than $7ff00.
  208.  
  209. NOTE: At the start  of  the  decrunching,  the  decruncher  loads
  210. registers $dff096, $dff09a and $dff09e with $7fff, thus disabling
  211. EVERY interrupt, all DMA and clears all ADK stuff. Therefore, you
  212. will have to enable ALL interrupts,  DMA, and ADK in the program,
  213. or by setting the appropriate  bits  in the values entered in the
  214. cruncher. Most games, however,  should  be  entered with all this
  215. stuff disabled.
  216.  
  217. NOTE II:  The  mega-decruncher  also  turns  off  the drive motor
  218. before starting the decrunching.
  219.  
  220.  
  221.                              RESULTS
  222.                             ---------
  223.  
  224. How efficient is the TetraPacker compared to other packers???
  225.  
  226. Well,  here's  some  figures   aquired   crunching  Katakis  with
  227. megacrunch on, and crunching  with  mega-pack  in Flashpacker and
  228. also the sizes  aquired  when  crunching  with  Byte-Killer.  One
  229. should note that the only  version  that worked by just crunching
  230. it straight away, without any  patches  or transferrers was, yes,
  231. TETRAPACK!!!
  232.  
  233. Scan-W.   TP-TIME/Size    RSI-Time/Size  Byte-Time/Size
  234.  
  235. $0080       1:00, 89252    1:10,92908     1:00, 96224
  236. $0100       1:40, 87112    1:50,89168     1:45, 91216
  237. $0200       3:00, 85132    3:15,86828     3:10, 88124
  238. No time to check $0400 out!!!
  239. $0800      11:20, 84660   11:30,85216    12:05, 86704
  240. $1000      22:00, 84812   22:10,85216    Not Available
  241. $2000      43:40, 85108   Not tested     Not Available
  242.  
  243. By these figures we can quite  easily  see  that TETRAPACK is THE
  244. BEST!! Just compare TP's $0200 to  ByteKiller's and RSI's $0800 -
  245. better result, but only taking one fourth of the time!!!
  246.  
  247. We can also see, that $0800 is the very best ScanWidth to choose,
  248. because when a bigger value  is  chosen,  the  files  also become
  249. bigger!!
  250.  
  251.                              EXAMPLE
  252.                             ---------
  253.  
  254. If you want  to  check  this  out  by  yourself,  then  the  file
  255. 'Katakis.c0' lies on this disk,  it  contains all the code on the
  256. first Katakis diskette. Use the following parameters:
  257.  
  258. IF YOU HAVE 1MB:
  259.  
  260. MEGACRUNCH: YES
  261. Lo-Mem: $c0
  262. Hi-Mem: $78000
  263. Scan-Width: $xxx
  264. Load-Type: o
  265. FileName: df0:Katakis.c0
  266. Load-Address: $c0
  267. JMP-Address: $c0
  268. DMA: $7fff
  269. INT: $7fff
  270. ADK: $7fff
  271. Status: $2700
  272. Stack: $7fffe
  273. Decruncher: $7f000
  274. FileName: xxxx
  275.  
  276. IF YOU HAVE 512K:
  277. ------------------
  278.  
  279. MEGACRUNCH: NO
  280. Lo-Mem: $c0
  281. Hi-Mem: $50000
  282. Scan-Width: $xxx
  283. Load-Type: o
  284. FileName: df0:Katakis.c0
  285. Load-Address: $c0
  286. JMP-Address: $c0
  287. PRO-DECRUNCHER: YES
  288. DMA: $7fff
  289. INT: $7fff
  290. ADK: $7fff
  291. Status: $2700
  292. Stack: $7fffe
  293. Decruncher: $7f000
  294. FileName: xxxx
  295.  
  296. Run it, insert Katakis datadisk in DF0:, then watch it run!!
  297.  
  298.  
  299.                          HINTS AND TIPS...
  300.                         -------------------
  301.  
  302. x Read this instruction through before using the packer to avoid
  303.   misunderstandings.
  304.  
  305. x If you are working on a project and need to crunch it now and
  306.   then, why not  write a TetraPack SCRIPT file?? Enter a editor
  307.   like TXEd (lies on this disk) or Ed on WorkBench, and type in
  308.   your info like this: (separated with RETURN's)
  309.   USE NO EMPTY LINES BETWEEN  PARAMETERS (except when the inst-
  310.   ructions tell you).
  311.  
  312. Y or N                          (MegaPack desired??)
  313. LoMem                           (in hex, don't include $)
  314. HiMem                           (also in hex, don't include $)
  315. Scan-Width                      (as above)
  316.  
  317. for each file/sectors:
  318.  
  319. T/O/R                           (Track, Ordinary, or Reloc)
  320. FileName                        (not when doing TrackLoad)
  321. LoadAddress                     (in hex, no $ included)
  322. and if TrackLoad:
  323. Offset                          (as above)
  324. Length                          (as above)
  325.  
  326. end file loading with two empty lines.
  327.  
  328. JMP-address                     (in hex, no $ included)
  329. FlashRegister                   (as above)
  330.  
  331. If not MEGACrunch: Y or N       (Use MEGA-depacker??)
  332.  
  333. If MEGACrunch or MEGADepack:
  334.  
  335. DMACON                          (DMA ENABLES)
  336. INTENA                          (INT ENABLES)
  337. ADKCON                          (ADK ENABLES)
  338. Status                          (SR Value)
  339. Decruncher                      (Decruncher location)
  340.  
  341. And then:
  342.  
  343. SaveFileName                    (save filename)
  344. Y/N                             (Want to run when saved???)
  345.  
  346. Save the file, and then, when you want to crunch using the SCRIPT
  347. file, enter:
  348.  
  349. TetraPack <SCRIPTFILENAME    (That is, type the name of your
  350.                              scriptfile instead of SCRIPTFILENAME...)
  351.  
  352.  
  353. THE LAST WORDS:
  354. ---------------
  355.  
  356. If you have an idea for a  new  feature,  or  if you (against all
  357. odds) FIND A BUG! in TetraPack, then write or phone to:
  358.  
  359.                       STEFAN BOBERG
  360.                       TYNNE BJORKE
  361.                       62023 ROMAKLOSTER
  362.                       SWEDEN
  363.  
  364.                       Tel: (+43) 0498-54076
  365.  
  366.                           AT ONCE!!
  367.  
  368.  
  369. THE VERY LAST WORD...
  370.  
  371.      LOOK OUT FOR TETRAPACK VERSION 3.0, MUCH IMPROVED VERSION!!!
  372.                         (The ultimate!)
  373.  
  374.                 Signed: AntiAction of TETRAGON.
  375.  
  376. Final note: There is a BUGGED version of TetraPack in ciculation,
  377. the version is 2.0, please,  delete